import request from "@/utils/request";

//上传图片时，获取oss数据
export const aliOssSecurityToken = () => {
  return request({
    url: "sass/file/getAliOssSecurityToken",
    method: "get"
  });
};

//查询商品规格list
export const getSpecificationList = props => {
  return request({
    url: "/mall/admin/specification/getSpecificationList",
    method: "post",
    data: props
  });
};

//添加、编辑商品规格
export const saveSpecification = props => {
  return request({
    url: "/mall/admin/specification/saveSpecification",
    method: "post",
    data: props
  });
};

//删除商品规格
export const deleteSpecification = props => {
  return request({
    url: "/mall/admin/specification/deleteSpecification",
    method: "delete",
    params: props
  });
};

//复制商品规格
export const copySpecification = props => {
  return request({
    url: "/mall/admin/specification/copySpecification",
    method: "post",
    data: props
  });
};
